/* Základní viditelnost a struktura – z předchozí verze */
.home-age-filter {
    display: block !important;
    visibility: visible !important;
    opacity: 1 !important;
    height: auto !important;
    min-height: 250px !important;
    overflow: visible !important;
    max-width: 1200px !important;
    margin: 40px auto !important;
    padding: 20px !important;
    background-color: #f9f9f9 !important;
    border-radius: 15px !important;
    box-shadow: 0 4px 10px rgba(0,0,0,0.1) !important;
    text-align: center !important;
    position: relative !important;
    z-index: 10 !important;
}

/* Grid pro tlačítka – původní horizontální no-wrap se scrollbar */
.haf-grid {
    display: flex !important;
    flex-direction: row !important;
    flex-wrap: nowrap !important;
    justify-content: flex-start !important;
    gap: 18px !important;
    overflow-x: auto !important;
    overflow-y: hidden !important;
    scroll-behavior: smooth !important;
    padding-bottom: 10px !important;
    touch-action: pan-x !important;
}

.haf-grid::-webkit-scrollbar {
    height: 8px !important;
}

.haf-grid::-webkit-scrollbar-thumb {
    background-color: rgba(0,0,0,0.2) !important;
    border-radius: 10px !important;
}

/* Styl tlačítek – původní velikost, gradienty, efekty */
.haf-btn {
    display: flex !important;
    align-items: center !important;
    justify-content: center !important;
    width: 120px !important;
    height: 120px !important;
    text-decoration: none !important;
    border-radius: 50% !important;
    font-size: 16px !important;
    font-weight: bold !important;
    color: #333 !important;
    text-shadow: 1px 1px 2px rgba(0,0,0,0.3) !important;
    text-align: center !important;
    transition: transform .15s ease-out, box-shadow .15s !important;
    box-shadow: 0 4px 8px rgba(0,0,0,0.2) !important;
    line-height: 1.4 !important;
    padding: 12px !important;
    word-break: break-word !important;
    hyphens: auto !important;
    white-space: normal !important;
    flex-shrink: 0 !important;
    box-sizing: border-box !important;
    overflow: visible !important;
}

.haf-btn:hover {
    transform: scale(1.05) !important;
    box-shadow: 0 5px 10px rgba(0,0,0,0.25) !important;
}

/* Původní gradienty pro jednotlivé věkové skupiny (neutrální verze) */
.haf-btn--do-1-roku { background: linear-gradient(135deg, #e3f2fd, #81d4fa) !important; }
.haf-btn--1-2-roky { background: linear-gradient(135deg, #fffde7, #fff59d) !important; }
.haf-btn--2-plus { background: linear-gradient(135deg, #e8f5e9, #a5d6a7) !important; }
.haf-btn--3-plus { background: linear-gradient(135deg, #fff3e0, #ffcc80) !important; }
.haf-btn--predskolaci { background: linear-gradient(135deg, #ffebee, #f48fb1) !important; }
.haf-btn--skolaci-1st { background: linear-gradient(135deg, #e3f2fd, #90caf9) !important; }
.haf-btn--skolaci-2st { background: linear-gradient(135deg, #f3e5f5, #b39ddb) !important; }

/* Vánoční motiv: SVG rámeček s barvením filtrem (jen rámeček, průhledné pozadí) */
.home-age-filter.christmas-mode {
    background: linear-gradient(to bottom, #f0f8ff, #e0f7fa) !important;  /* Lehce sněhové pozadí */
    box-shadow: 0 4px 10px rgba(0,0,0,0.1) !important;  /* Zachování stínu */
}

.home-age-filter.christmas-mode .haf-btn {
    color: #fff !important;  /* Bílý text pro kontrast */
    text-shadow: 2px 2px 4px rgba(0,0,0,0.5) !important;  /* Silnější stín pro čitelnost */
    background-image: url('https://www.hrackovna.cz/user/documents/upload/uprava%20sablony/Ozdoba_ramecek.svg') !important;  /* Tvá SVG verze rámečku */
    background-size: contain !important;
    background-repeat: no-repeat !important;
    background-position: center !important;
    background-color: transparent !important;  /* Průhledné pozadí – žádné podbarvení mimo rámeček */
    border-radius: 0 !important;  /* Žádný kruh */
    width: 200px !important;  /* Přesná velikost pro SVG */
    height: 200px !important;
    border: none !important;
    box-shadow: 0 4px 12px rgba(0,0,0,0.3) !important;  /* 3D efekt */
}

/* Různé barvy pro SVG rámeček (hue-rotate – upravte stupně pro doladění) */
.home-age-filter.christmas-mode .haf-btn--do-1-roku { filter: hue-rotate(0deg) saturate(1.5) brightness(1.1) !important; }  /* Červený tón */
.home-age-filter.christmas-mode .haf-btn--1-2-roky { filter: hue-rotate(120deg) saturate(1.5) brightness(1.1) !important; }  /* Zelený tón */
.home-age-filter.christmas-mode .haf-btn--2-plus { filter: hue-rotate(30deg) saturate(1.5) brightness(1.1) !important; }  /* Zlatý/oranžový */
.home-age-filter.christmas-mode .haf-btn--3-plus { filter: hue-rotate(210deg) saturate(1.5) brightness(1.1) !important; }  /* Modrý */
.home-age-filter.christmas-mode .haf-btn--predskolaci { filter: hue-rotate(350deg) saturate(1.5) brightness(1.1) !important; }  /* Růžový */
.home-age-filter.christmas-mode .haf-btn--skolaci-1st { filter: hue-rotate(240deg) saturate(1.5) brightness(1.1) !important; }  /* Tmavě modrý */
.home-age-filter.christmas-mode .haf-btn--skolaci-2st { filter: hue-rotate(270deg) saturate(1.5) brightness(1.1) !important; }  /* Fialový */

/* Volitelný sněhový efekt (animované vločky) – smažte, pokud ruší */
.home-age-filter.christmas-mode::before {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background: url('data:image/svg+xml;utf8,<svg xmlns="http://www.w3.org/2000/svg" viewBox="0 0 100 100"><circle cx="50" cy="50" r="5" fill="white" opacity="0.8"/></svg>') repeat;  /* Jednoduché vločky */
    animation: snow 10s linear infinite;
    pointer-events: none;
    opacity: 0.3;
}
@keyframes snow {
    0% { background-position: 0 0; }
    100% { background-position: 0 100px; }
}

/* Další původní prvky (haf-title, age-chip, haf-arrows) – pokud je používáš */
.haf-title { font-size: 28px !important; margin-bottom: 50px !important; color: #333 !important; font-weight: bold !important; }  /* Zachování většího odstupu */
.age-chip { position: fixed !important; bottom: 20px !important; left: 20px !important; background-color: #4caf50 !important; color: white !important; padding: 10px 20px !important; border-radius: 50px !important; box-shadow: 0 2px 5px rgba(0,0,0,0.2) !important; display: flex !important; align-items: center !important; z-index: 9999 !important; }
.age-chip-text { margin-right: 10px !important; font-size: clamp(16px, 1.6vw, 18px) !important; }
.age-chip button { background: none !important; border: none !important; color: white !important; cursor: pointer !important; font-size: clamp(16px, 1.6vw, 18px) !important; }
.haf-arrows { display: none !important; }
@media (max-width: 1024px) { .haf-arrows { display: flex !important; justify-content: center !important; gap: 20px !important; margin-top: 10px !important; } .haf-arrow { background: transparent !important; border: none !important; cursor: pointer !important; transition: transform 0.2s !important; opacity: 0.8 !important; } .haf-arrow:hover { transform: scale(1.1) !important; opacity: 1 !important; } }

/* Responsivita – upravena pro SVG tlačítka v christmas-mode */
@media (max-width: 800px) {
    .haf-grid { justify-content: flex-start !important; gap: 10px !important; padding: 0 !important; padding-left: 0 !important; margin-left: 0 !important; scroll-padding-left: 0 !important; overflow-x: scroll !important; overflow-y: hidden !important; touch-action: pan-x !important; }
    .haf-btn { width: 80px !important; height: 80px !important; font-size: 12px !important; padding: 6px !important; }
    .christmas-mode .haf-btn { width: 120px !important; height: 120px !important; font-size: 12px !important; }
}

@media (max-width: 1024px) {
    .haf-grid { justify-content: flex-start !important; gap: 14px !important; padding: 0 !important; margin-left: 0 !important; scroll-padding-left: 0 !important; overflow-y: hidden !important; touch-action: pan-x !important; }
    .haf-btn { width: 100px !important; height: 100px !important; font-size: 14px !important; padding: 8px !important; }
    .christmas-mode .haf-btn { width: 150px !important; height: 150px !important; font-size: 14px !important; }
}

@media (max-width: 1024px) and (orientation: portrait) {
    .haf-grid { justify-content: flex-start !important; margin-left: 0 !important; padding-left: 0 !important; overflow-y: hidden !important; }
}

@media (min-width: 1025px) {
    .haf-grid { justify-content: center !important; gap: 24px !important; }
}

/* Reset konfliktů – pro stabilitu */
.home-age-filter * {
    box-sizing: border-box !important;
    margin: 0 !important;
    padding: 0 !important;
    visibility: visible !important;
    opacity: 1 !important;
}
